package com.gbk.clickhouseservicestruct.model;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.myweb.ck.mapping.ChTable;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

@ChTable(name = "tig.T_TIG_STAGE_TRAFFIC")
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class TIG_Phase_Traffic {

    /**
     * ID 主键 唯一 报警表id
     */
    private String id;

    /**
     * 路口ID
     */
    private String crossId;

    /**
     * 周期开始时间
     */
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date cycleStart;

    /**
     * 相位编号
     */
    private int stageId;

    /**
     * 相位开始时间
     */
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date startTime;

    /**
     * 相位持续时间
     */
    private int stageTime;

    /**
     * 绿损时间
     */
    private String greenLoss;

    /**
     * 启动延迟
     */
    private String startDelay;

    /**
     * 车头时距均值
     */
    private String headwayMean;

    /**
     * 车头时距标准差
     */
    private String headwaySd;

    /**
     * 车头时距最小值
     */
    private String headwayMin;

    /**
     * 车头时距最大值
     */
    private String headwayMax;

    /**
     * 车头时距数据个数
     */
    private String headwayNum;

    /**
     * 红灯末最小排队数据
     */
    private String minRedsVehs;

    /**
     * 红灯末最大排队数据
     */
    private String maxRedsVehs;

    /**
     * 绿灯初最小排队数据
     */
    private String minGreensVehs;

    /**
     * 绿灯初最大排队数据
     */
    private String maxGreensVehs;

    /**
     * 各流向车道总值
     */
    private int volume_01;
    private int volume_02;
    private int volume_03;
    private int volume_04;
    private int volume_05;
    private int volume_06;
    private int volume_07;
    private int volume_08;
    private int volume_09;
    private int volume_10;
    private int volume_11;
    private int volume_12;
    private int volume_13;
    private int volume_14;
    private int volume_15;
    private int volume_16;

    /**
     * 各流向车道最大值
     */
    private int maxVolume_01;
    private int maxVolume_02;
    private int maxVolume_03;
    private int maxVolume_04;
    private int maxVolume_05;
    private int maxVolume_06;
    private int maxVolume_07;
    private int maxVolume_08;
    private int maxVolume_09;
    private int maxVolume_10;
    private int maxVolume_11;
    private int maxVolume_12;
    private int maxVolume_13;
    private int maxVolume_14;
    private int maxVolume_15;
    private int maxVolume_16;

    private String phaseNos;

}


